
<!--
To change this template, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://java.sun.com/jsf/core" >

    <h:head>

        <title>Cadastrar Senha</title>
    </h:head>

    <h:body>
        <ui:composition xmlns:ui="http://java.sun.com/jsf/facelets"
                        template="../comum/Template.xhtml">
            <ui:define name="content">
                <p:ajaxStatus style="width:16px;height:16px; " id="ajaxStatusPanel"> 
                    <f:facet name="start">  
                        <p:graphicImage value="/images/ajaxloadingbar.gif" />  
                    </f:facet>  

                    <f:facet name="complete">  
                        <h:outputText value="" />  
                    </f:facet>  
                </p:ajaxStatus>      
                <h:form id="form2">  
                    <p:panel id="panel" header="Cadastrar Senha - Dados Entrada" style="width: 600px; margin: 10% auto;">

                        <p:messages id="msgs" />

                        <h:panelGrid id="grid" columns="3" cellpadding="5">  

                            <h:outputText value="Tipo usuário: " />  
                            <p:selectOneButton  id="tpUser" required="true" requiredMessage="Selecione o tipo do usuário" >  
                                <f:selectItem itemLabel="Funcionario" itemValue="Option 1" />  
                                <f:selectItem itemLabel="Aluno" itemValue="Option 2" />  
                            </p:selectOneButton >  
                            <p:message id="tex" for="tpUser"  display="text" />  

                            <h:outputText value="RG *" />  
                            <p:inputMask id="rg" mask="99.999.999-99" value="#{cadastrar.rg}" 
                                         required="true" requiredMessage="Campo necessário." />  
                            <p:message id="rgMessage" for="rg"  display="text" />  

                            <h:outputText value="Codigo Escola: *" />  
                            <p:inputText id="textOnly1" required="true" requiredMessage="Campo necessário." />  
                            <p:message id="textOnlyMessage1" for="textOnly1" display="text" />  

                            <h:outputText value="RA: *" />  
                            <p:inputText id="textOnly2" required="true" requiredMessage="Campo necessário."  />  
                            <p:message id="textOnlyMessage2" for="textOnly2" display="text" />  

                            <h:outputText value="Data Nascimento: *" />  
                            <p:inputMask  id="textOnl3y" required="true" mask="99/99/9999" requiredMessage="Campo necessário."  />  
                            <p:message id="textOnlyMessage3" for="textOnl3y" display="text" />  



                        </h:panelGrid>  
                        <p:commandButton id="confirmar" value="Confirmar" action="#{cadastrar.cadastrar()}" update="grid"/>  
                        <p:commandButton id="voltar" value="Voltar" action="#{cadastrar.voltar()}" update="grid"/>  
                    </p:panel>  
                </h:form>  
            </ui:define>
        </ui:composition>
    </h:body>
</html>

